package com.qf.day3;

public class Demo3 {
    public static void main(String[] args) {
        int x,y,z;
        for (x=0;x<=30;x++){
            for (y = 0; y <30-x ; y++) {
                z=30-x-y;
                if((x+y+z)==30 && x*3+y*2+z ==50){
                    System.out.println("x:"+x+" "+"y:"+y+" "+"z:"+z);
                }
            }
        }
    }
}
